<template>
    <el-table
            :data="tableData"
            row-key="indexId"
            border
            default-expand-all
            :cell-style="tableCellStyle"
            :header-cell-style="tableHeaderCellStyle"
            style="width: 100%; margin: 20px 0;border:1px solid black;"
            :tree-props="{children: 'children', hasChildren: 'hasChildren'}">
        <el-table-column
                prop="indexDesc"
                label="指标名称">
            <template slot-scope="scope">
                <span v-if="scope.row.partFlag === true" style="font-weight: bold;font-size: 20px;">{{ scope.row.indexDesc }}</span>
                <span v-else>{{ scope.row.indexDesc }}</span>
            </template>
        </el-table-column>
<!--        <el-table-column-->
<!--                prop="reginEvalScore"-->
<!--                align="center"-->
<!--                label="区县自评"-->
<!--                width="100">-->
<!--        </el-table-column>-->
        <el-table-column
                prop="expertEvalScore"
                align="center"
                label="能力等级"
                width="100">
        </el-table-column>
    </el-table>
</template>

<script>
import {partList} from '@/utils/data'

export default {
	props: {
		tableData : {
			type : Array,
			default: (() => {
				return []
			})
		}
	},
	data () {
		return {

		}
	},
    methods: {
        // 修改 table cell边框的背景色，行高，字体大小
        tableCellStyle() {
            return 'border-color: black; font-size:20px;height:50px'
        },
        // 修改 table header cell的背景色，行高，字体大小
        tableHeaderCellStyle() {
            return 'border-color: black; color: black; background:#FFFFFF;font-size:20px;height:50px'
        },
    }
}
</script>

<style lang="scss" scoped>

</style>
